package com.blog.zip.mapper;

import com.blog.zip.bean.SiteLink;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Update;

import java.util.List;

public interface SiteLinkMapper {
    public Integer addLink(SiteLink siteLink);

    public List<SiteLink> getLink(SiteLink siteLink);

    @Update("update zip_blog_link set url = #{url} ,description = #{description},weight = #{weight},title = #{title},type = #{type} " +
            ", image = #{image} where zid = #{zid}")
    public void updateLink(SiteLink siteLink);

    @Delete("delete from zip_blog_link where zid = #{id}")
    public void deleteLink(Integer id);

}